package com.pactera.asmp.server.service;

import com.pactera.asmp.server.entity.*;
import com.pactera.asmp.server.pojo.ScriptInfo2;
import com.pactera.asmp.server.pojo.TaskStartupInfo;
import com.pactera.asmp.server.pojo.TestReport;
import com.pactera.asmp.server.pojo.TestReportErrorVideoInfo;
import com.pactera.asmp.server.utils.PageDataResult;
import java.util.List;

/**
 * @ProjectName: asmp-server
 * @Package com.pactera.asmp.server.service
 * @ClassName: ITestReportService
 * @Description:
 * @Date 2020/08/06 13:53
 * @Author lvzhiqiang
 * @Version 1.0
 */
public interface ITestReportService {

    boolean insert(TestReport testReport);
    boolean insert(TestReportDTO testReportDTO);

    boolean delete(List<Integer> datas);

    boolean update(TestReport testReport);

    PageDataResult select(TestReportSearchDTO testReportSearchDTO);

    List<TaskReportChartVO> getTaskReportCategoryChart(Integer taskId);
    List<TaskReportChartVO> getTaskReportCategoryChart2(List<Integer> idsList,List<ScriptInfo2> scriptInfos);
    List<TaskReportChartVO> getTaskReportModuleChart(Integer taskId);
    List<TaskReportChartVO> getTaskReportModuleChart2(List<Integer> idsList,List<ScriptInfo2> scriptInfos);
    List<TaskReportListVO> getTaskReportList(List<TaskDTO> taskDTOs);

    List<Integer> getScriptIdsByProjectId(Integer projectId);
    List<TaskReportChartVO> getProjectReportChartByCategory(List<Integer> scriptIds);
    List<TaskReportChartVO> getProjectReportChartByModule(List<Integer> scriptIds);
    List<TaskReportListVO> getProjectReportChartModuleExec(List<Integer> scriptIds,Integer projectId);

    List<SelectTestReportResult> selectAll(Integer taskId);

    int insertBatch(List<TestReportDTO> reports);

    ResponseResult getTestReportDataByProject(Integer projectId);

    ResponseResult getTestReportDataByTask(Integer taskId);
    ResponseResult getTestReportDataByTaskScripts(Integer taskId);

    ResponseResult getFailReports(Integer taskId, Integer moduleId);

    ResponseResult getFileLog(String fileName);

    List<TestReportErrorVideoInfo> getErrorVideoInfosByTestReportId(Integer testReportId);
    List<TestReportApplicationResponseTime> getTestReportApplicationResponseTime(Integer testReportId);
    List<TaskStartupInfo> getTaskStartupInfo(Integer taskId);
}
